<template>
 <div>
     <header @click="$router.push('/Home')">砍价列表</header>
     <van-card
     v-for="item in list"
     :key="item.id"
        num="2"
        price="2.00"
        :desc="item.characteristic"
        :title="item.name"
        :thumb="item.pic"
        >
        <template v-slot:price>
            <ul class="price">
                <li>
                    <p>￥0.9</p>
                    <p>底价</p>
                </li>
                <li>
                    <p>￥0.9</p>
                    <p>底价</p>
                </li>
            </ul>
        </template>
        </van-card>
 </div>
</template>

<script>
export default {
  name: "",
  data() {
    return {
      list: []
    };
  },
  mounted() {
    this.getList();
  },
  methods: {
    async getList() {
      let { data: res } = await this.$http.get(
        "https://api.it120.cc/small4/shop/goods/kanjia/list"
      );
      // console.log(res.data.goodsMap);
      this.list = res.data.goodsMap;
    }
  },
  computed: {},
  watch: {}
};
</script>

<style scoped>
* {
  margin: 0;
  padding: 0;
}
header {
  width: 100%;
  height: 50px;
  line-height: 50px;
  text-align: center;
}
img {
  width: 158px;
  height: 158px;
}
</style>